]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
telepathyClient.js: use ShellTpClient instead of TpSimpleObserver
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Wed, 23 Mar 2011 10:22:42 +0000 (11:22 +0100)
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Wed, 27 Apr 2011 08:43:17 +0000 (10:43 +0200)
https://bugzilla.gnome.org/show_bug.cgi?id=645585

js/ui/telepathyClient.js

index 33f4e870713ec4faedbfd2a5fa686fd4d7cb8721..5e3f33c972b7b9c6562d127962d8022d1b431f62 100644 (file)
@@ -80,14 +80,9 @@ Client.prototype = {
         // The second argument, recover, means _observeChannels will be run
         // for any existing channel as well.
         let dbus = Tp.DBusDaemon.dup();
-        this._observer = Tp.SimpleObserver.new(dbus, true, 'GnomeShell', true,
-                                              Lang.bind(this, this._observeChannels));
-
-        // We only care about single-user text-based chats
-        let props = {};
-        props[Tp.PROP_CHANNEL_CHANNEL_TYPE] = Tp.IFACE_CHANNEL_TYPE_TEXT;
-        props[Tp.PROP_CHANNEL_TARGET_HANDLE_TYPE] = Tp.HandleType.CONTACT;
-        this._observer.add_observer_filter(props);
+        this._observer = Shell.TpClient.new(dbus);
+        this._observer.set_observe_channels_func(
+            Lang.bind(this, this._observeChannels));
 
         try {
             this._observer.register();